#ifndef STARTUP_H
#define STARTUP_H

#include <QWidget>
#include <QPaintEvent>
#include <QPainter>
#include "devchecker.h"
#include "blldataflow.h"
#include "ettadatastruct.h"
#include "bllcontroller.h"
#include "selfcheckfail.h"
#include "project.h"

namespace Ui {
class StartUp;
}

class StartUp : public QWidget
{
    Q_OBJECT

public:
    explicit StartUp(QWidget *parent = nullptr);
    ~StartUp();

public slots:
    void onProgressChanged(int val);
    //self check
    void selfCheckPassSlot(const HostReply &reply);
    void selfCheckFailSlot(const HostReply &reply);
    void retranslateUiSlot();

protected:
    void showEvent(QShowEvent *);

private slots:
    void on_pbtnOK_clicked();
    void setWidgetParent();

private:
    void initWidget();

private:
    Ui::StartUp *ui;
    DevChecker * dcThread;
    BllDataFlow * bdf;
    BllController * bCtrl;
    SelfCheckFail * selfCheckFailDialog;
    bool userSkipSelfCheck;
    int progressCount;
};

#endif // STARTUP_H
